#!/bin/bash
sudo passwd root
#配置ssh服务
ssh-keygen -q -t rsa -b 2048 -f /etc/ssh/ssh_host_rsa_key -N '' -y
ssh-keygen -q -t ecdsa -f /etc/ssh/ssh_host_ecdsa_key -N '' -y
ssh-keygen -t dsa -f /etc/ssh/ssh_host_ed25519_key -N '' -y


ssh-keygen -t rsa -b 4096 -C "1813033378@qq.com" -Y






#设置 ssh 配置文件
sed -i "s/#UsePrivilegeSeparation.*/UsePrivilegeSeparation\\ no/g" /etc/ssh/sshd_config

sed -i "s/#PermitRootLogin.*/PermitRootLogin\\ yes/g" /etc/ssh/sshd_config
sed -i "s/UsePAM.*/UsePAM\\ yes/g" /etc/ssh/sshd_config


apt-get install --reinstall openssh-server
getent passwd
userdel -r he_qiao

/mnt/gradle-8.8-bin.zip

wget https://gitcode.net/qq_29578241/qqtv/-/raw/master/shell/%E7%B3%BB%E7%BB%9F%E5%9F%BA%E6%9C%AC%E4%BD%BF%E7%94%A8/ubunt/install-%E5%AE%89%E8%A3%85%E5%88%9D%E5%A7%8B%E5%8C%96.sh?inline=false


deluser --remove-home qq









#修改root密码
echo "root:1813033378" | chpasswd

cat >> /etc/apt/sources.list << EOF

deb https://mirrors.aliyun.com/ubuntu/ focal main restricted universe multiverse
deb-src https://mirrors.aliyun.com/ubuntu/ focal main restricted universe multiverse

deb https://mirrors.aliyun.com/ubuntu/ focal-security main restricted universe multiverse
deb-src https://mirrors.aliyun.com/ubuntu/ focal-security main restricted universe multiverse

deb https://mirrors.aliyun.com/ubuntu/ focal-updates main restricted universe multiverse
deb-src https://mirrors.aliyun.com/ubuntu/ focal-updates main restricted universe multiverse

# deb https://mirrors.aliyun.com/ubuntu/ focal-proposed main restricted universe multiverse
# deb-src https://mirrors.aliyun.com/ubuntu/ focal-proposed main restricted universe multiverse

deb https://mirrors.aliyun.com/ubuntu/ focal-backports main restricted universe multiverse
deb-src https://mirrors.aliyun.com/ubuntu/ focal-backports main restricted universe multiverse


EOF
apt-get update
reboot








